home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-01 / pdcurs21.zip / NONPORT.ZIP / WBORDER.C < prev    next >
Text File  |  1992-11-21  |  1KB  |  46 lines

  1. #define        CURSES_LIBRARY  1
  2. #include <curses.h>
  3. #undef wborder
  4.  
  5. #ifndef        NDEBUG
  6. char *rcsid_wborder = "$Header: c:/curses/nonport/RCS/wborder.c%v 2.0 1992/11/15 03:18:29 MH Rel $";
  7. #endif
  8.  
  9.  
  10.  
  11.  
  12. /*man-start*********************************************************************
  13.  
  14.   wborder()    - sets the border characters in the passed window.
  15.  
  16.   PDCurses Description:
  17.        This routine sets the border characters for the passed window.
  18.  
  19.   PDCurses Return Value:
  20.        This function returns OK upon success otherwise ERR is returned.
  21.  
  22.   PDCurses Errors:
  23.        It is an error for stdscr to be a NULL pointer.
  24.  
  25.   Portability:
  26.        PDCurses        int wborder( chtype l,  chtype r,  chtype t,  chtype b,
  27.                                    chtype tl, chtype tr  chtype bl, chtype br );
  28.  
  29. **man-end**********************************************************************/
  30.  
  31. int    wborder(WINDOW *win,chtype l,chtype r,chtype t,chtype b,chtype tl,chtype tr,chtype bl,chtype br)
  32. {
  33.        if (win == (WINDOW *)NULL)
  34.                return( ERR );
  35.  
  36.        win->_borderchars[0] = l;
  37.        win->_borderchars[1] = r;
  38.        win->_borderchars[2] = t;
  39.        win->_borderchars[3] = b;
  40.        win->_borderchars[4] = tl;
  41.        win->_borderchars[5] = tr;
  42.        win->_borderchars[6] = bl;
  43.        win->_borderchars[7] = br;
  44.        return( OK );
  45. }
  46.